<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>一次性生活补助</title>
    <link rel="stylesheet" href="./styles/web/index.css">
    <link rel="stylesheet" href="./styles/web/print.css" type="text/css" media="print">
    <style>
        .error_info {
            left: 130px;
        }
    </style>
</head>

<body>
    <div class="all">
        <!-- 头部开始 -->
        <script src="http://rsj.beijing.gov.cn/images/rsj_header.js"></script>
        <include src="./include/header.html"></include>
        <!-- 头部结束 -->
        <!-- 申请提示开始 -->
        <div class="message clearfix">
            <div class="content clearfix">
                <div class="zuo left scroll">
                    <div class="first common">
                        <div class="titles concommon">
                            <a href="./index.html">
                                < 首页</a> <span class="on">|</span>
                                    <span>申领</span>
                        </div>
                        <div class="allzs zscommon J_info">
                            <form name="form_lhjy" msgtype="2" validate="blur">
                                <div class="cards valiflag khh text_pad" id="selects"
                                    style="margin-top: 20px;height: auto;">
                                    <div class="card_text clearfix" style="position: relative;">
                                        <span class='card_left left'>本人银行卡姓名：</span>
                                        <p type="text" class="card_p left xmxq J_xm"></p>
                                    </div>
                                    <div class="card_text clearfix" style="position: relative;">
                                        <span class='card_left left'>本人银行卡类型：</span>
                                        <select class='left Jgmc' name="" id="J_yhklx" style="margin-left:10px"
                                            paramete="yhklx" v_require valiflag="2,,本人银行卡类型,false">
                                        </select>
                                    </div>
                                    <div class="card_text clearfix" style="position: relative;">
                                        <span class='card_left left'>本人银行开户行：</span>
                                        <select class='left Jgmc' name="" id="J_khh" style="margin-left:10px"
                                            paramete="khh" v_require valiflag="2,num,本人银行开户行,false">
                                        </select>
                                    </div>
                                    <div class="card_text clearfix" style="position: relative;">
                                        <span class='card_left left'>本人银行卡账号：</span>
                                        <input type="text" class="card_right left J_one" style="text-indent: 8px;"
                                            id="J_yhzh" paramete="yhzh" placeholder="" v_require
                                            valiflag="20,number,本人银行卡账号,false">
                                    </div>
                                    <div class="card_text clearfix" style="position: relative;">
                                        <span class='card_left left'>请再次输入账号：</span>
                                        <input type="text" class="card_right left J_two" style="text-indent: 8px;"
                                            id="J_yhzh" paramete="yhzh" placeholder="" v_require
                                            valiflag="20,number,再次输入账号,false">
                                    </div>
                                </div>
                            </form>
                            <div class="comall xq_wxts">
                                <p class="" style="color: red;">温馨提示:</p>
                                <p class="black" style="text-indent:2em;margin-bottom: 4px;">1.请使用与<span
                                        class="col_red">本人姓名</span>信息一致的银行卡。</p>
                                <p class="black" style="text-indent:2em;margin-bottom: 4px;">
                                    2.为保证失业保险金及时到账请尽量不要变更正确的银行卡信息。
                                </p>
                                <p class="black" style="text-indent:2em;margin-bottom: 4px;">3.银行卡信息<span
                                        class="col_red">变更后</span>将对次月发放待遇有效</p>
                            </div>
                            <div class="comall sl_bz">
                                <p class="" style="color: red;">备&nbsp&nbsp注：</p>
                                <p class="black" style="text-indent:2em;margin-bottom: 4px;line-height: 20px;">
                                    工商银行、光大银行、华夏银行、建设银行、交通银行、民生银行、农业银行、邮政储蓄银行、招商银行、中国银行、中信银行、兴业银行、浦发银行13家银行<span
                                        class="col_red">支持本市、外埠开卡代发业务</span>。北京农商银行、北京银行、广发银行3家银行<span
                                        class="col_red">仅适用本市开卡代发业务</span>。</p>
                            </div>
                            <div class="comall btn_wrap no_print" style="margin-top: 20px;">
                                <button class="btn btn_blue_deep J_save">保存</button>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="you right">
                    <div class="top">
                        <div class="person on">
                            <p class="on xm"></p>
                            <p class="lxdh"></p>
                        </div>
                        <p class="sfzhm"></p>
                    </div>
                    <div id="J_tcwrap">
                        <script type="text/html" id="J_tcitem">
                         <%if(data.executeResult == 1){%>
                             <% var _data = data.baseInfo%>
                        <div class="middle">
                             <%if(_data.xszt){%>
                                    <div class="yyxx_box">
                                        <p class="zjyyxx" style="width: 160px;">
                                            <span>审核状态：</span>
                                            <span class="yhzh" title="<%=_data.xszt%>"><%=_data.xszt%></span>
                                        </p>
                                        <a href="#" class="J_jl">历次申领记录查询</a>
                                    </div>
                                <%}else{%>
                                    <h3 class="">暂无申领记录</h3>     
                                <%}%> 
                            </div>
                            <div class="middle">
                                    <%if(_data.yhzh){%>
                                           <div class="yyxx_box clearfix"> 
                                            <p class="zjyyxx left" style="width: 176px;">
                                                <span>银行账号：</span>
                                                <span class="yhzh" title="<%=_data.yhzh%>"><%=_data.yhzh%></span>
                                            </p>
                                            <button  class="right J_yhk">银行账号变更</button>
                                        </div>  
                                       <%}else{%>
                                        <h3 class="">暂无银行账号信息</h3>   
                                       <%}%> 
                                   </div>
                    <%}%>
                </script>
                    </div>
                    <div class="newbox">
                        <div class="box_two">
                            <p class="zxtel">咨询电话：12333</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <!-- 申请提示结束 -->
    <!-- 尾部开始 -->
    <script src="http://rsj.beijing.gov.cn/footer.js"></script>
    <!-- 尾部结束 -->
    </div>
    <!-- 弹框开始 -->
</body>
<script src="./common/js/vendor.js"></script>
<script src="./common/js/jquery.js"></script>
<script src="./common/js/validator.js"></script>
<script src="./common/js/template-native.js"></script>
<script src="./common/js/common.js"></script>
<script>
    $(function () {
        var loading = new $.Loading();
        var sqid, yhzhbg, yhzhwh, lastdayoftheM;
        getGrxx();//获取人员信息
        getLcyyxc(); //历次预约查询
        getYyhzhCx(); //原银行账户信息查询
        $.renderCodeOther('/sybxjsl/dmblbCx', $('#J_yhklx'), 'sybxj_d_yhklx'); //银行卡类型代码表
        $.renderCodeOther('/sybxjsl/dmblbCx', $('#J_khh'), 'sybxj_d_khh');//开户行代码表

        //确认密码不允许复制粘贴
        $(".J_two").on("copy cut paste", function (e) {
            return false;//禁止密码框复制/剪切/粘贴
        })

        // 保存
        $(document).on('click', '.J_save', function () {
            if (!validate('form_lhjy')) return false;
            if ($('.J_one').val() != $('.J_two').val()) {
                $.layerMsg('两次录入银行账号不一致！', '确定');
                return false;
            }
            var getFormData = $('form[name="form_lhjy"]').getFormData();
            $.layerMsg("是否确认保存？", [
                {
                    text: '确认',
                    cb: function () {
                        loading.on();
                        $.fetch({
                            url: '/Nmgycxshbz/sqSave',
                            type: 'post',
                            data: getFormData
                        }).done(function (result) {
                            if (result.returnData.executeResult === '1') {
                                $.layerMsg('您的申请已受理，可通过"历次申领记录查询"查看办理进度。通过网上申领一次性生活补助,将在5个工作日内完成审核。', '确定', function () {
                                    window.location.href = "./index.html";
                                }, 5, 'text-indent:2em;text-align:left;')
                            } else {
                                $.layerMsg(result.returnData.message, '确定');
                            }
                        }).always(function(){
                            loading.off();
                        })
                    }
                },
                { text: '取消', }
            ]
            )
        });

        //原银行账户信息查询
        function getYyhzhCx() {
            $.asyncRender({
                url: '/Nmgycxshbz/yyhzhCx/1',
                type: 'get',
                wrap: '#J_wrap1',
                tem: '#J_item1',
                pos: 'returnData'
            }).done(function (result) {
                var msg = result.returnData;
                if (msg.executeResult == "1") {
                    if (msg.dataList) {
                        yhzhwh = msg.dataList[0]
                    }
                } else {
                    $.layerMsg(msg.message, '确定')
                }
            })
        }

        //右侧银行账号变更
        $(document).on('click', '.J_yhk', function () {
            if (lastdayoftheM == '1') {
                $.layerMsg('每月最后一天因资金结算期，银行账号变更功能暂停，请在其他时间进行银行账号变更，谢谢理解和支持。', '确定')
            } else if (lastdayoftheM == '0') {
                if (yhzhwh) {
                    $('.J_yhk').attr("disabled", false);
                    window.location.href = "./yhkwh.html";
                } else {
                    $('.J_yhk').attr("disabled", true);
                }
            }
        });

        // 退出登录
        $(document).on('click', '.exit', function () {
            $.logout();
        });
    });
</script>

</html>